import api from '../api';
import { PINGVALIDATEURL } from '../../utils/constant'
// // Permission Management Page

// ping id 验证
export const pingIdValidate = info => api.post(PINGVALIDATEURL, info);
// 验证身份
export const usersAuthorized = info => api.post('/api/sys/user/permission/authorized', info);
// 登出
export const outLogin = info => api.get(`/api/sso/logout?user=${info.user}`, info);
// 通知
export const noticeList = info => api.post('/api/sys/notice/list', info);

// 点击了通知后发生api
export const noticeEdit = info => api.post('/api/sys/notice/edit', info);


export const apiPermissionList = info => api.post('/api/sys/user/permission/list', info);
export const apiPermissionEmailList = info => api.post('/api/sys/user/permission/select', info);
export const apiPermissionFilter = info => api.get('/api/sys/user/permission/filter', info);
export const apiPermissionAdd = info => api.post('/api/sys/user/permission/add', info);
export const apiPermissionEdit = info => api.post('/api/sys/user/permission/edit', info);
export const apiPermissionFileUpload = info => api.post('/api/oss/upload', info);
export const apiPermissionRemove = info => api.post('/api/sys/user/permission/remove', info);
export const apiPermissionView = info => api.post('/api/sys/user/permission/view', info);
export const apiPermissionNameCheck = info => api.post('/api/sys/user/permission/name/count', info);
export const apiPermissionDownload = info => api.post('/api/sys/user/permission/download', info);
export const apiPermissionApproveSelect = info => api.post('/api/sys/user/permission/approve/select', info);
export const apiPermissionAll = info => api.post('/api/sys/user/permission/all', info);